-- GENERATED SPELL FOR [Master Engineer Telonicus] --


function spell0_20063(pUnit, Event) --@Bomb,n/a--
pUnit:FullCastSpellOnTarget(37036,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20063', 1500, 1)
end

function spell1_20063(pUnit, Event) --@Remote Toy,n/a--
pUnit:FullCastSpellOnTarget(37027,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20063', 0, 1)
end

function spell2_20063(pUnit, Event) --@Shoot,n/a--
pUnit:FullCastSpellOnTarget(16496,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20063', 633, 1)
end

function Sorts_20063(pUnit, Event)
local choix_sorts_20063 = math.random(0, 2)
if choix_sorts_20063 == 0 then
pUnit:RegisterEvent('spell0_20063', 1, 1)
end
if choix_sorts_20063 == 1 then
pUnit:RegisterEvent('spell1_20063', 1, 1)
end
if choix_sorts_20063 == 2 then
pUnit:RegisterEvent('spell2_20063', 1, 1)
end
end

function mob20063_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_20063', math.random(1500, 3000), 1)
end

function mob20063_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob20063_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob20063_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(20063, 1, 'mob20063_Action')
RegisterUnitEvent(20063, 2, 'mob20063_Leave')
RegisterUnitEvent(20063, 3, 'mob20063_Kill')
RegisterUnitEvent(20063, 4, 'mob20063_Die')
